import request from "@/utils/request";




export function findstoe(params) {
  return request({
    url: "/sinohis/pension/profession/bedmanager/building/condition",
    method: 'get',
    params

  });

}
export function findroom(params) {
  return request({
    url: "/sinohis/pension/profession/bedmanager/room/condition",
    method: 'get',
    params

  });

}
export function add(data,type) {
  return request({
    url: "/sinohis/pension/profession/bedmanager/bed",
    method: type,
    data

  });

}
export function search(params) {
  return request({
    url: "/sinohis/pension/profession/bedmanager/bed/condition",
    method: 'get',
    params

  });

}
export function doDelete(params) {
  return request({
    url: "/sinohis/pension/profession/bedmanager/bed/remove/"+params.number+'/'+params.institutionNumber+'/'+params.roomCode+'/'+params.floor+'/'+params.unit+'/'+params.bedCode,
    method: 'DELETE',
    params

  });

}
//禁用床位

export function disable(data) {
  return request({
    url: "/sinohis/pension/profession/bedmanager/room/disablebed/"+data.number+'/' + data.institutionNumber+'/'+data.roomCode+'/' + data.floor+'/'+data.unit+'/'+data.bedCode,
    method: "PUT",
    data

  });

}
//启用床位
export function enablebed(data) {
  return request({
    url: "/sinohis/pension/profession/bedmanager/room/enablebed/"+data.number+'/' + data.institutionNumber+'/'+data.roomCode+'/' + data.floor+'/'+data.unit+'/'+data.bedCode,
    method: "PUT",
    data

  });

}
